import matplotlib

from Detector.ComprehensiveFaultDetector import ComprehensiveFaultDetector

# 使用示例
if __name__ == "__main__":

    matplotlib.rc('font', family='STHeiti')
    matplotlib.rc('axes', unicode_minus=False)


    detector = ComprehensiveFaultDetector('11.25故障录波')

    # 分步执行
    try:
        detector.load_and_parse_files()
        detector.load_and_process_data()
        detector.extract_device_data()
        detector.initialize_fault_detection_system()

        # 执行检测
        results = detector.detect_all_devices_faults()

        for result in results:
            print(result)

    except Exception as e:
        raise e
